package com.rockcent.mall.lib.dto;

import com.rockcent.common.domain.DtoEntity;

import java.math.BigDecimal;

/**
 * Created by DK on 16/11/20.
 */
public class CustomerFundDto extends DtoEntity {

    //总金额
    private BigDecimal totalAmount;

    //冻结金额
    private BigDecimal frozen;

    //可用金额
    private BigDecimal availableAmount;

    //累计收入
    private BigDecimal income;

    //累计支出
    private BigDecimal expend;

    //客户ID
    private Long customerId;

    //昵称
    private String nickName;

    //手机号码
    private String mobile;

    //待使用的卡券
    private Long toUseCountCoupon = 0L;
    //待使用的现金前
    private Long toUseCountCash = 0L;

    public BigDecimal getTotalAmount() {
        return totalAmount.setScale(2, BigDecimal.ROUND_HALF_UP);
    }

    public void setTotalAmount(BigDecimal totalAmount) {
        this.totalAmount = totalAmount;
    }

    public BigDecimal getFrozen() {
        return frozen.setScale(2, BigDecimal.ROUND_HALF_UP);
    }

    public void setFrozen(BigDecimal frozen) {
        this.frozen = frozen;
    }

    public BigDecimal getAvailableAmount() {
        return availableAmount.setScale(2, BigDecimal.ROUND_HALF_UP);
    }

    public void setAvailableAmount(BigDecimal availableAmount) {
        this.availableAmount = availableAmount;
    }

    public BigDecimal getIncome() {
        return income.setScale(2, BigDecimal.ROUND_HALF_UP);
    }

    public void setIncome(BigDecimal income) {
        this.income = income;
    }

    public BigDecimal getExpend() {
        return expend.setScale(2, BigDecimal.ROUND_HALF_UP);
    }

    public void setExpend(BigDecimal expend) {
        this.expend = expend;
    }

    public Long getCustomerId() {
        return customerId;
    }

    public void setCustomerId(Long customerId) {
        this.customerId = customerId;
    }

    public String getNickName() {
        return nickName;
    }

    public void setNickName(String nickName) {
        this.nickName = nickName;
    }

    public String getMobile() {
        return mobile;
    }

    public void setMobile(String mobile) {
        this.mobile = mobile;
    }

    public Long getToUseCountCoupon() {
        return toUseCountCoupon;
    }

    public void setToUseCountCoupon(Long toUseCountCoupon) {
        this.toUseCountCoupon = toUseCountCoupon;
    }

    public Long getToUseCountCash() {
        return toUseCountCash;
    }

    public void setToUseCountCash(Long toUseCountCash) {
        this.toUseCountCash = toUseCountCash;
    }

    @Override
    public String toString() {
        return "CustomerFundDto{" +
                "totalAmount=" + totalAmount +
                ", frozen=" + frozen +
                ", availableAmount=" + availableAmount +
                ", income=" + income +
                ", expend=" + expend +
                ", customerId=" + customerId +
                ", nickName='" + nickName + '\'' +
                ", mobile='" + mobile + '\'' +
                ", toUseCountCoupon=" + toUseCountCoupon +
                ", toUseCountCash=" + toUseCountCash +
                '}';
    }
}
